function FirstAssistant() {
	this.counter = 0;
}

FirstAssistant.prototype.setup = function() {
	this.controller.get("app-title").update(Mojo.appInfo.title);
	this.controller.get("app-id").update(Mojo.appInfo.id);
	this.controller.get("app-version").update(Mojo.appInfo.version);
	var c = this.controller, e = Mojo.Event;
	c.setupWidget('button', {}, {label: 'Inc Counter'});

	c.listen('button',e.tap, this.onTap.bind(this));
	c.get('counter').update(this.counter);

	c.setupWidget('swap', {}, {label: 'SwapScene'});
	c.listen('swap',e.tap, this.onSwap.bind(this));
};
FirstAssistant.prototype.onTap = function() {
	var c = this.controller;
	this.counter = this.counter + 2;
	c.get('counter').update(this.counter);
	console.log('counter at: ' + this.counter);
};

FirstAssistant.prototype.onSwap = function() {
	var c = this.controller;
	c.stageController.swapScene('second');

};

FirstAssistant.prototype.activate = function(event) {
};

FirstAssistant.prototype.deactivate = function(event) {
};

FirstAssistant.prototype.cleanup = function(event) {
};
